import request from '@/utils/request'

export function login(params) {
  return request ({
    url: "/login",
    method: 'post',
    params
  })
}

export function register(data) {
  return request ({
    url: "/home/register",
    method: 'post',
    data
  })
}


export function code() {
  return request ({
    url: "/api/captcha",
    method: 'get',
  })
}
/**
 * 
 *  修改用户信息
 */

export function edit(data) {
  return request({
    url: `/home/updateUser`,
    method: 'post',
    data
  }) 
}